﻿namespace IPlugin
{


    public enum EnumWarningLevel
    {
        Normal,
        Warning,
        Urgency
    }
    /// <summary>
    /// 变量状态
    /// </summary>
    public enum EnumVariableStatus
    {
        Unknow= 0,
        AddressError,
        MethodError,
        ExpressionError,
        Bad,
        Good,
    }
    /// <summary>
    /// 设备状态
    /// </summary>
    public enum EnumDeviceStatus
    {
        Good = 0,
        PartGood,
        Bad,
        Unkown
    }

    /// <summary>
    /// 只读，只写，读写
    /// </summary>
    public enum EnumProtectType
    {
        ReadOnly = 0,
        ReadWrite,
        WriteOnly
    }
    /// <summary>
    /// 字节序
    /// </summary>
    public enum EnumDataFormat
    {
        /// <summary>
        /// 按照顺序排序
        /// </summary>
        ABCD = 0,
        /// <summary>
        /// 按照倒序排序
        /// </summary>
        DCBA = 1,
        /// <summary>
        /// 按照单字反转
        /// </summary>
        BADC = 2,
        /// <summary>
        /// 按照双字反转
        /// </summary>
        CDAB = 3,

    }


    /// <summary>
    /// 数据类型
    /// </summary>
    public enum EnumDataType
    {
        Bit = 0,
        Bool,
        UByte,
        Byte,
        Uint16,
        Int16,
        Uint32,
        Int32,
        Float,
        Uint64,
        Int64,
        Double,
        String,
        AsciiString,
        Utf8String,
        Gb2312String,
        Int,
        DInt,
        Real,
        UInt,
        UDInt,
        USInt,
        SInt,
        Char,
        Time,
        Word,
        DWord,
        UInt64,
        DTL
    }
    /// <summary>
    /// 设备连接状态
    /// </summary>
    public enum EnumConnectStatus
    {
        Disconnected = 0,
        Connected
    }

    public enum EnumAggregate
    {
        /// <summary>
        /// 不使用
        /// </summary>
        None,
        /// <summary>
        /// 平均数
        /// </summary>
        Mean,
        /// <summary>
        /// 中值
        /// </summary>
        Median,
        /// <summary>
        /// 最后一个值
        /// </summary>
        Last,
        /// <summary>
        /// 第一个值
        /// </summary>
        First,
        /// <summary>
        /// 最大
        /// </summary>
        Max,
        /// <summary>
        /// 最小
        /// </summary>
        Min,
        /// <summary>
        /// 合计
        /// </summary>
        Sum
    }

    public enum EnumClientType
    {
        Main,
        Client,
        Upload,
        Unload,
        Server
    }
}
